﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using Common.DataTypes;

namespace Common.DataTypes
{
    public class Book : Item
    {
        //public string Keyword { get; set; }
        public string Author { get; set; }
        public string Isbn { get; set; }
        public string PublicationDate { get; set; }
        public string Publisher { get; set; }
        public string ReleaseDate{ get; set; }

        public Book() { }

        

        public void AssignProperty(int property_type, object value)
        {
            switch (property_type)
            {
                case Item.ASIN:
                    this.Asin = (string)value;
                    break;
                case Item.AUTHOR:
                    this.Author = (string)value;
                    break;
                case Item.BINDING:
                    this.Binding = (string)value;
                    break;
                case Item.DETAILPAGEURL:
                    this.DetailPageUrl = (string)value;
                    break;
                case Item.EAN:
                    this.Ean = (string)value;
                    break;
                case Item.ISBN:
                    this.Isbn = (string)value;
                    break;
                case Item.LABEL:
                    this.Label = (string)value;
                    break;
                case Item.LARGEIMAGE:
                    this.LargeImage = (string)value;
                    break;
                case Item.LISTPRICE:
                    this.ListPrice = (ListPriceData)value;
                    break;
                case Item.MANUFACTURER:
                    this.Manufacturer = (string)value;
                    break;
                case Item.MEDIUMIMAGE:
                    this.MediumImage = (string)value;
                    break;
                case Item.PACKAGEDIMENSIONS:
                    this.PackageDimensions = (string)value;
                    break;
                case Item.PUBLICATIONDATE:
                    this.PublicationDate = (string)value;
                    break;
                case Item.PUBLISHER:
                    this.Publisher = (string)value;
                    break;
                case Item.RELEASEDATE:
                    this.ReleaseDate = (string)value;
                    break;
                case Item.SALESRANK:
                    this.SalesRank = (string)value;
                    break;
                case Item.SMALLIMAGE:
                    this.SmallImage = (string)value;
                    break;
                case Item.STUDIO:
                    this.Studio = (string)value;
                    break;
                case Item.TITLE:
                    this.Title = (string)value;
                    break;
            }
        }
    }
}
